#ifndef __INIPARSER_H__                                                                                                                                                                                           
#define __INIPARSER_H__


#include <iostream>
#include <fstream>
#include <vector>
#include <map>
#include <algorithm>


typedef std::map<std::string, std::string> ssmap;
typedef std::map<std::string, ssmap> INIMAP;
#define MAX_BUF_SIZE  512


class INIParser {

	public:
		INIParser(const char* inifile_name){

			inifile = inifile_name;

			comments.push_back('#');
			comments.push_back(';');
		}   
		~INIParser(){
		}

	public:
		int parser();
		ssmap& getKeyValBySection(const char* section);
	public:
		const char* inifile;
		INIMAP inimap;
		std::vector<char>comments;

};
#endif
